package cn.edu.scau.cmi.dengzejun.chapter11;

import javax.swing.*;
import java.awt.*;

public class BorderLayoutJPanel extends JPanel{
	JButton	bSouth,bNorth,bEast,bWest;
	JTextArea bCenter;
	BorderLayoutJPanel(){
		this.setLayout(new BorderLayout());
		this.bSouth = new JButton("South");
		this.bNorth = new JButton("North");
		this.bEast = new JButton("East");
		this.bWest = new JButton("West");
		this.bCenter = new JTextArea("Center");
		this.add(bNorth,BorderLayout.NORTH);
		this.add(bSouth, BorderLayout.SOUTH);
		this.add(bEast, BorderLayout.EAST);
		this.add(bWest, BorderLayout.WEST);
		this.add(bCenter, BorderLayout.CENTER);
		return;
	}
}
